import React, { Component } from 'react'

export default class Child1 extends Component {
  handleClick = () => {
    // !#2 emit 触发事件
    this.emitter.emit('changeCount', 2)
  }
  render() {
    return (
      <div>
        Child1<button onClick={this.handleClick}>+1</button>
      </div>
    )
  }
}
